﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="productAdd.aspx.cs" Inherits="Admin_productAdd" EnableEventValidation="false" %>


<%@ Register Assembly="CuteEditor" Namespace="CuteEditor" TagPrefix="CE" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>商品添加</title>
              <link rel="stylesheet" type="text/css" media="all" href="js/ext/resources/css/ext-all.css" />
	<script type="text/javascript" src="js/ext/adapter/ext/ext-base.js"></script>
	<script type="text/javascript" src="js/ext/ext-all.js"></script>	
	<script type="text/javascript" src="js/ext/ext-lang-zh_CN.js"></script>
	<script type="text/javascript" src="js/product_add.js"></script>
    <link rel="stylesheet" type="text/css" media="all" href="css/ext-common.css" />
 
    <style type="text/css">
        body,th {
	        font-size: 14px;
	        font-weight : bolder ;
        }
        td{
            
            font-size: 14px;
	        font-weight : bolder ;
	        background-color:#E8ECEF;
	        vertical-align:middle;
	        
        }
        tr{ 
            height:22px;
        } 
        input 
        {
            font-size:12px;
        }
        .inputText
        {
            border-width:1px;
            border-color:#ACA899;
            border-style:solid;
            
        }
    </style>
</head>
<body>
    <form id="form1" runat="server">
    <div>
    <div id="tabs1"  style="margin-left:10px; margin-top:10px; width:800;">
        <asp:ScriptManager ID="ScriptManager1" runat="server"  EnablePageMethods="true" EnablePartialRendering="true">
        </asp:ScriptManager>
        <div id="tabBase" style="  height:450px; background-color:#E8ECEF;" ><br />
            <table style="margin-left:10px; width:750px;background-color:Gray;" cellpadding="1" border="0" cellspacing="1"  >
                <tr>
                    <td style="width:80px; ">&nbsp;名称： </td>
                    <td colspan="3"> 
                         <asp:TextBox ID="txtName" runat="server" CssClass="inputText" Width="600"></asp:TextBox></td>
                    
                </tr>
                
                <tr>
                    <td style="width:80px; ">&nbsp;底部标题：
                    </td>
                    <td colspan="3"> 
                         <asp:TextBox ID="txtTitle" runat="server" CssClass="inputText" Width="600"></asp:TextBox></td>
                    
                </tr>
                <tr>
                    <td style="width:80px; height: 22px;">&nbsp;品牌：</td>
                    <td style="width:315px; height: 22px;"><asp:DropDownList ID="ddlBrand" runat="server" DataTextField="brand_name" DataValueField="brandID"  >
                        </asp:DropDownList> </td>
                    <td style="width:80px; height: 22px;">&nbsp;类型：</td>
                    <td style="height: 22px"> 
                        <asp:DropDownList ID="ddlType" runat="server" DataTextField="typeName" DataValueField="typeId">
                        </asp:DropDownList>
                         </td>
                </tr>
                <tr>
                    <td>&nbsp;编号：</td>
                    <td style="width: 315px">
                        <asp:TextBox ID="txtNO" runat="server" CssClass="inputText"></asp:TextBox> </td>
                    <td>&nbsp;款式：</td>
                    <td>
                        <asp:DropDownList ID="ddlSex" runat="server">
                            <asp:ListItem>女款</asp:ListItem>
                            <asp:ListItem>男款</asp:ListItem>
                        </asp:DropDownList>
                        <asp:TextBox ID="txtStyle" runat="server" CssClass="inputText" ></asp:TextBox>
                         
                         </td>                    
                </tr>
                <tr>
                    <td>&nbsp;服装特点： </td>
                    <td colspan="3"> 
                        <asp:TextBox ID="txtEspecial" runat="server" CssClass="inputText" Width="600"></asp:TextBox></td>
                    
                </tr>              
                <tr>
                    <td>&nbsp;材质：</td>
                    <td style="width: 315px">
                        <asp:TextBox ID="txtMaterial" runat="server" CssClass="inputText" Width="283px"></asp:TextBox></td>
                    <td>&nbsp;服装季节：</td>
                    <td>
                        <asp:DropDownList ID="ddlExpiryYear" runat="server" Width="99px">
                            <asp:ListItem>2011</asp:ListItem>
                            <asp:ListItem Selected="True">2012</asp:ListItem>
                            <asp:ListItem>2013</asp:ListItem>
                            <asp:ListItem>2014</asp:ListItem>
                            <asp:ListItem>2015</asp:ListItem>
                            <asp:ListItem>2016</asp:ListItem>
                            <asp:ListItem>2017</asp:ListItem>
                            <asp:ListItem>2018</asp:ListItem> 
                        </asp:DropDownList>
                        &nbsp;
                        <asp:DropDownList ID="ddlExpirySeason" runat="server" Width="101px">
                            <asp:ListItem Value="0">春季</asp:ListItem>
                            <asp:ListItem Value="1">夏季</asp:ListItem>
                            <asp:ListItem Value="2">秋季</asp:ListItem>
                            <asp:ListItem Value="3">冬季</asp:ListItem>
                        </asp:DropDownList></td>
                </tr>
                <tr>
                    <td>&nbsp;成本：</td>
                    <td style="width: 315px">
                        <asp:TextBox ID="txtCostPrice" runat="server" CssClass="inputText"></asp:TextBox></td>
                    <td>&nbsp;单位：</td>
                    <td>
                        <asp:DropDownList ID="ddlUnit" runat="server" Width="100px">
                            <asp:ListItem>件</asp:ListItem>
                            <asp:ListItem>套</asp:ListItem>
                        </asp:DropDownList></td>
                </tr>
                <tr>
                    <td>&nbsp;全价：</td>
                    <td style="width: 315px">
                        <asp:TextBox ID="txtWholePrice" runat="server" CssClass="inputText"></asp:TextBox></td>
                    <td>&nbsp;重量：</td>
                    <td>
                        <asp:TextBox ID="txtWeight" runat="server"></asp:TextBox>(克)</td>
                </tr>
                <tr>
                    <td>&nbsp;折后价：</td>
                    <td style="width: 315px">
                        <asp:TextBox ID="txtRetailPrice" runat="server" CssClass="inputText"></asp:TextBox></td>
                    <td>&nbsp;</td>
                    <td><asp:TextBox ID="txtID" runat="server" CssClass="inputText" Text="0" style="display:none;"></asp:TextBox></td>
                </tr>
                <tr style=" height:200px;">
                    <td style="vertical-align:top;">&nbsp;尺码：</td>
                    <td  style="vertical-align:top; width: 315px;"> 
                    <asp:UpdatePanel ID="upSize" runat="server"  ChildrenAsTriggers="False" UpdateMode="Conditional">
                        <ContentTemplate>
                            <asp:DropDownList ID="ddlSizeMaterial" runat="server" OnSelectedIndexChanged="ddlSizeMaterial_SelectedIndexChanged" DataTextField="sizeMatName" DataValueField="sizeMatID" AutoPostBack="True">
                            </asp:DropDownList>
                            <asp:CheckBoxList ID="chkListSize" runat="server" DataTextField="sizeName" DataValueField="sizeID">
                            </asp:CheckBoxList>
                        </ContentTemplate>
                        <Triggers>
                            <asp:AsyncPostBackTrigger ControlID="ddlSizeMaterial" EventName="SelectedIndexChanged" />
                        </Triggers>
                        </asp:UpdatePanel> </td>
                    <td style="vertical-align:top;">
                        颜色</td>
                    <td style="vertical-align:top;"> 
                        <asp:CheckBoxList ID="cblColorGroup" runat="server" DataTextField="col_color" DataValueField="colID">
                        </asp:CheckBoxList></td>
                </tr>

            </table>
        </div>
        <div id="tabImg" style=" height:450px;background-color:#E8ECEF;" class="x-hide-display">
           <table style="margin-left:10px; width:750px;background-color:Gray;" cellpadding="1" border="0" cellspacing="1"  >
              <tr>
                <td style="width:114px">左侧显示图片：</td>
                <td style="width:395px"> 
                    <asp:FileUpload ID="fuLftShowPic" runat="server" Width="380px" />
                     </td>
                <td>
                    <asp:Image ID="imgLft" runat="server" Width="50" Height="40" />
                </td>
                <td style="width: 100px">(1024*800)</td>    
              </tr>
              <tr>
                <td style="width:114px;">基本信息图片：</td>
                <td style="width: 395px">
                    <asp:FileUpload ID="fuBasicInformationPic" runat="server" Width="380px" />
                     </td>
                 <td><asp:Image ID="imgBasic" runat="server" Width="50" Height="40" /></td>
                <td>(520 * 780)</td>    
              </tr>
              <tr>
                <td style="width:114px;">细节图片：</td>
                <td style="width: 395px">
                    <asp:FileUpload ID="fuDetailsPic" runat="server" Width="380px"/> 
                                                </td>
                <td><asp:Image ID="imgDetail" runat="server" Width="50" Height="40" /></td>
                <td>
                    (宽：750<br />
                    高：无限制)</td>    
              </tr>
              <tr>
                <td style="width:114px; height: 22px;">展示图片：</td>
                <td style="width: 395px; vertical-align:top; height: 22px;">
                    <p id="MyFile"><input id="File1" type="file" name="FileShow" runat="server" style="width:380px;"/></p>
                    <input onclick="addFile()" type="button" value="增加图片"/>
                              
                </td>
                <td style="height: 22px">
                    <table id="tblShowPics" width="100%" >
                    <asp:Repeater ID="rptShowPic" runat="server">
                        <ItemTemplate>
                            <tr PathFile='<%#  Eval("fileName")  %>'>
                            <td style="width:80px;">
                                <asp:Image ID="imgPic"  Width="50" Height="40" runat="server" ImageUrl='<%# Eval("imgURL") %>' />
                            </td>
                            <td style="vertical-align:middle;  "   align="center">
                                <img alt="" src="images/mail/mail_remove.png" onclick="DeleteImg('<%# Eval("fileName") %>')" title="删除" style="cursor:hand" />
                            </td>
                            </tr>
                        </ItemTemplate>
                    </asp:Repeater>
                    </table>
                </td>
                <td style="height: 22px">
                    (600 * 900)</td>   
                 
              </tr>
            </table>
            <div style="color:#ff0000; margin-left:10px; margin-top:3px; font-size:12px;">
                说明:上传总图片大小为4M,超出会出错
            </div>
        </div>
        <div id="tabDes" style="margin-left:2px; margin-top:2px;height:450px" class="x-hide-display">
             <CE:Editor ID="edit_content" runat="server" AutoConfigure="Simple" CodeViewTemplateItemList="Cut,Copy,Paste,Find"
                Height="100%" Width="100%">
            </CE:Editor>
        
        </div>
        
    </div> 
    </div>
    <center>
        <asp:Button ID="BtnSave" runat="server" Text="保 存" OnClick="BtnSave_Click" />
        <input type="button" value="返回列表" onclick="window.location.href='productManager.aspx';" />
        </center>
    </form>
</body>
</html>
